package frsf.cidisi.exercise.modelo.situationCalculus;

import frsf.cidisi.faia.agent.Agent;
import frsf.cidisi.faia.agent.situationcalculus.SituationCalculusPerception;
import frsf.cidisi.faia.environment.Environment;

public class AgentePerception extends SituationCalculusPerception {

  	
	//TODO: Setup Sensors
/*    private Laberinto laberinto;
	private List<Coordenada> listaEntradas;
	private List<Salida> listaSalidas;
	private List<Coordenada> listaLlaves;
	private int percepcion;*/
	private boolean llave;
	private boolean salida;
	private boolean cerrada;
	private boolean paredN;
	private boolean paredS;
	private boolean paredE;
	private boolean paredO;
	
	

    public AgentePerception() {
        super();

		//TODO: Complete Method
/*    	laberinto = null;
    	listaEntradas = null;
    	listaSalidas = null;
    	listaLlaves = null;*/
        llave = false;
        salida = false;
        cerrada = false;
        paredN = false;
        paredS = false;
        paredE = false;
        paredO = false;
    }

    @Override
    public void initPerception(Agent agentIn, Environment environmentIn) {
        /*Ambiente environment = (Ambiente) environmentIn;
        AmbienteEstado environmentState = environment.getEnvironmentState();
        
        this.setLaberinto(environmentState.getLaberinto());
        this.setListaEntradas(environmentState.getListaEntradas());
        this.setListaLlaves(environmentState.getListaLlaves());
        this.setListaSalidas(environmentState.getListaSalidas());*/
    }

    @Override
    public String toString() {
        StringBuffer perceptionString = new StringBuffer("perception([");
        //TODO: Complete Method
        perceptionString.append(this.llave ? "llave" : "0");
        perceptionString.append(",");
        perceptionString.append(this.salida ? "salida" : "0");
        perceptionString.append(",");
        perceptionString.append(this.cerrada ? "cerrada" : "0");
        perceptionString.append("],");
        perceptionString.append(this.paredN ? "pared" : "0");
        perceptionString.append(",");
        perceptionString.append(this.paredS ? "pared" : "0");
        perceptionString.append(",");
        perceptionString.append(this.paredE ? "pared" : "0");
        perceptionString.append(",");
        perceptionString.append(this.paredO ? "pared" : "0");

        perceptionString.append(")");

        return perceptionString.toString();
    }

	public boolean isLlave() {
		return llave;
	}

	public void setLlave(boolean llave) {
		this.llave = llave;
	}

	public boolean isSalida() {
		return salida;
	}

	public void setSalida(boolean salida) {
		this.salida = salida;
	}

	public boolean isCerrada() {
		return cerrada;
	}

	public void setCerrada(boolean cerrada) {
		this.cerrada = cerrada;
	}

	public boolean isParedN() {
		return paredN;
	}

	public void setParedN(boolean paredN) {
		this.paredN = paredN;
	}

	public boolean isParedS() {
		return paredS;
	}

	public void setParedS(boolean paredS) {
		this.paredS = paredS;
	}

	public boolean isParedE() {
		return paredE;
	}

	public void setParedE(boolean paredE) {
		this.paredE = paredE;
	}

	public boolean isParedO() {
		return paredO;
	}

	public void setParedO(boolean paredO) {
		this.paredO = paredO;
	}
    
    
/*     public int getpercepcion(){
        return percepcion;
     }
     public void setpercepcion(int arg){
        this.percepcion = arg;
     }

 	public void setLaberinto(Laberinto laberinto) {
		this.laberinto = laberinto;
	}

	public Laberinto getLaberinto() {
		return laberinto;
	}

	public void setListaEntradas(List<Coordenada> listaEntradas) {
		this.listaEntradas = listaEntradas;
	}

	public List<Coordenada> getListaEntradas() {
		return listaEntradas;
	}

	public void setListaSalidas(List<Salida> listaSalidas) {
		this.listaSalidas = listaSalidas;
	}

	public List<Salida> getListaSalidas() {
		return listaSalidas;
	}

	public void setListaLlaves(List<Coordenada> listaLlaves) {
		this.listaLlaves = listaLlaves;
	}

	public List<Coordenada> getListaLlaves() {
		return listaLlaves;
	}*/

}
